package com.cskaoyan.service;


import com.cskaoyan.bean.bo.*;
import com.cskaoyan.bean.bo.OrderSearchBo;
import com.cskaoyan.bean.entity.Channel;
import com.cskaoyan.bean.entity.Comment;
import com.cskaoyan.bean.entity.Order;
import com.cskaoyan.bean.entity.OrderGoods;
import com.cskaoyan.bean.vo.*;
import com.cskaoyan.exception.OrderSubmitException;

import java.util.List;

/**
 *  订单管理
 *
 */
public interface OrderService {

    // 根据参数查询订单
    BasePageData<Order> query(BaseParam baseParam, OrderSearchBo orderSearchBo);

    //回复商品评论
    int addreply(Comment comment);

    // 订单详情
    OrderDetailVo detail(Integer id);

    // 删除订单
    void delete(Integer id);

    // 获取所有的快递公司
    List<Channel> getChannel();

    // =================================前台===========================================

    BasePageData queryList(WxOrderListReqBo wxOrderListReqBo);

    WxOrderDetailVo queryOrderDetail(Integer orderId);


//    int insertComment(OrderCommentBo orderCommentBo);

    int insertComment(WxOrderCommentBo wxOrderCommentBo);

    // 用户主页 --->  订单信息
    WxUserIndexVo getUserIndex(Integer userId);

    // 订单取消
    int updateOrderCancel(WxOrderIdBo wxOrderIdBo);

    // 申请退款
    int updateOrderRefund(WxOrderIdBo wxOrderIdBo);

    // 删除订单
    int updateOrderDeleted(WxOrderIdBo wxOrderIdBo);

    // 确认收货
    int updateOrderConfirm(WxOrderIdBo wxOrderIdBo);

    OrderGoods queryOrderGoods(Integer orderId, Integer goodsId);

    WxOrderSubmitVo insertOrder(WxOrderSubmitBo wxOrderSubmitBo) throws OrderSubmitException;
}
